<template>
	<view class="content">
		<image class="logo" src="/static/logo.png"></image>
		<view class="text-area">
			<text class="title">{{title}}</text>
		</view>
		<u-modal :show="show" @confirm="confirm" ref="uModal"></u-modal>
		<view style="margin-left: 100rpx;margin-right: 100rpx;height: 80rpx;background: #c9c9c9;" @click="showModal">
			Alert</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				title: 'Hello',
				showAlert: false,
				show: false
			}
		},
		onLoad() {
			console.log("********************");
			let temp = uni.getStorageSync('read');
			console.log("read ", temp == '', temp == undefined)
			// if (uni.getStorageSync('read')) {
			// 	console.log("read 11")
			// } else {
			// 	console.log("read 22")
			// }
			// uni.setStorageSync('read', false);
			// console.log("read ", uni.getStorageSync('read'))
			// if (uni.getStorageSync('read')) {
			// 	console.log("read 33")
			// } else {
			// 	console.log("read 44")
			// }
		},
		methods: {
			clickHide() {
				console.log("----------")
			},
			showModal() {
				this.show = true;
			},
			confirm() {
				// setTimeout(() => {
				// this.show = false;
				// }, 3000)
				this.show = false;
			}
		}
	}
</script>

<style>
	.content {
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: center;
	}

	.logo {
		height: 200rpx;
		width: 200rpx;
		margin-top: 200rpx;
		margin-left: auto;
		margin-right: auto;
		margin-bottom: 50rpx;
	}

	.text-area {
		display: flex;
		justify-content: center;
	}

	.title {
		font-size: 36rpx;
		color: #8f8f94;
	}
</style>